using System;
using System.Collections.Generic;
using System.Linq;
using RMH.Entities;
using RMH.Services;

namespace RMH.Web.FakeServices
{
    public class FakeDiagnosisService : IDiagnosisService
    {
        private static List<Diagnosis> _diagnoses = new List<Diagnosis>
                                                          {
                                                              new Diagnosis() {Id = 1, Name = "Cancer"},
                                                              new Diagnosis() {Id = 2, Name = "Diabetes"},
                                                              new Diagnosis() {Id = 3, Name = "Athsma"},
                                                              new Diagnosis() {Id = 4, Name = "Alergies"}
                                                          };
        public IList<Diagnosis> GetAll()
        {
            return _diagnoses;
        }

        public Diagnosis Get(int id)
        {
            return _diagnoses.Where(d => d.Id == id).FirstOrDefault();
        }

        public void Save(Diagnosis item)
        {
            throw new NotImplementedException();
        }
    }
}